/********************************************************************************
* GDGA.h contain genetic algorithm for drawing graphs							*
*	GDGA				- drawing function; return number of iterations			*
*		Survivior			-	2*n array for final embedding					*
*		n					-	number of vertices								*
*		m					-	number of edges									*
*		MI					-	2*m incedence matrix							*
*	setCoefficients		-	set coefficients for evalFunction					*
*		mk1,mk4				-	koeff consider free space(+)					*
*		mk2,mk3				-	koeff consieder edge lengh deviation from		*
*							optimal(-)											*
*		mk5					-	koeff consider edge with edge and edge with		*
*							node crossings(-)									*
*	orientDraw			-	consider orientation of edges						*
*		mk6					-	koeff of considering(-)							* 
*	nonOrientDraw		-	don`t consider orientation of edges(mk6=0)			*
*	setElite			-	elite is count of parents, which always goes		*
*						to next generation										*
*	setMaxIterations	-	set upper limit of iterations of algorythm			*
*	setConvergence		-	set count of close population leaders to stop		*
*																				*
*					30.04.07													*
********************************************************************************/
#ifndef _GDGA_H_
#define _GDGA_H_

void setCoefficient(double mk1,double mk2,double mk3,double mk4,double mk5);
void setElite(int x);
void orientDraw(double mk6);
void nonOrientDraw();
int calculateGridSize(int x);
int GDGA(int *Survivior,int n,int m,int *MI);
void setMaxIterations(int x);
void setConvergence(int x);
void ShowEmbToArr(int gridSize,int *MI,int *Emb,int n,int m,int x,int y,int x1,int y1,float *V,float *E);
void GDGAToArr(int n,int m,int *MI,float *V,float *E,int x,int y,int x1,int y1);
#endif